package com.zhyl.demo.mapper;

import com.zhyl.demo.entity.Medication;
import org.apache.ibatis.annotations.Mapper;

import java.util.ArrayList;

/**
 * @author yang3
 */
@Mapper
public interface MedicationMapper {
    /**
     * 获取全部药品信息
     * @return
     */
    ArrayList<Medication> getMedicList();

    /**
     * 根据药品名模糊查询
     * @param medicName
     * @return
     */
    ArrayList getSelectMedic(String medicName);

    int updateMedic(Medication medication);

    int createMedic(Medication medication);

    int deleteMedic(Integer medId);

    Medication checkMedic(String name);
}
